package com.lmk;

import java.util.ArrayList;
import java.util.Collections;

public class DouDiZhu {
    public static void main(String[] args) {
        ArrayList<String> porker=new ArrayList<>();
        String[] colors={"♥","♣","◇","♠"} ;
        String[] numbers={"2","A","K","J","Q","10","9","8","7","6","5","4","3"};
        porker.add("大王");
        porker.add("小王");
        for (String number:numbers
             ) {
            for (String color:
                 colors) {
                porker.add(color+number);

            }
        }

        Collections.shuffle(porker);

        ArrayList<String> play1=new ArrayList<>();
        ArrayList<String> play2=new ArrayList<>();
        ArrayList<String> play3=new ArrayList<>();
        ArrayList<String> dipai=new ArrayList<>();


        for (int i = 0; i < porker.size(); i++) {
          String p=  porker.get(i);
            if(i>=51){
                dipai.add(p);
            }else if(i%3==0){
                play1.add(p);
            }else if(i%3==1){
                play2.add(p);
            }else if(i%3==2){
                play3.add(p);
            }
        }
        System.out.println("刘德华"+play1);
        System.out.println("周润发"+play1);

        System.out.println("张三"+play1);
        System.out.println("底牌"+dipai);



    }
}
